package com.treasure.web.controller;

import com.treasure.common.reponse.Response;
import com.treasure.web.command.response.AccountUserInfoResponse;
import com.treasure.web.service.IAccountService;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 账户信息 （用户端）
 *
 * @author sunhongmin
 * @date 2023/9/1 23:42
 * @description
 */
@RestController
@RequiredArgsConstructor
@RequestMapping("/treasure/account")
public class AccountController {
    private final IAccountService accountService;
    /**
     * 获取登录用户详细信息
     *
     * @return 登录用户详细信息
     */
    @PostMapping("/info")
    public Response<AccountUserInfoResponse> getUserInfo() {
        return Response.success(accountService.getAccountUserInfo());
    }

    // 编辑用户信息

}
